<%@ taglib uri="http://java.sun.com/jstl/core" prefix="c" %>
<%@ taglib uri="/WEB-INF/struts-bean.tld" prefix="bean"%>
<html>
<head>
<link href="<%=request.getContextPath()%>/theme/cssGeneral.css" rel="stylesheet" type="text/css">
<link href="<%=request.getContextPath()%>/theme/cssLink.css" rel="stylesheet" type="text/css">
<link href="<%=request.getContextPath()%>/theme/cssTexto.css" rel="stylesheet" type="text/css">
<link href="<%=request.getContextPath()%>/theme/cssFormulario.css" rel="stylesheet" type="text/css">
<script language="JavaScript" type="text/javascript" src="<%= request.getContextPath() %>/js/seccd.js"></script>
<script language="javascript">
var cont=0
function cancelar(){
	document.location="listarUsuarios.do?method=listarUsuarios";
}
function actualizar(){
	document.form.method.value="grabaEditaUsuario";
	document.form.action="grabaEditaUsuario.do";
	document.form.submit();
}
</script>
</head>
<body topmargin="0" bottommargin="0" leftmargin="0" rightmargin="0" onLoad="redimensionar()">
<c:set var="cod_perfil" value="${requestScope.usuarioTO.perfil}"/>
<c:set var="cod_estado" value="${requestScope.usuarioTO.estado}"/>
<form name="form" method="post">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
	<td align="left">
	<table cellpadding="0" cellspacing="0" border="0" width="1">
	<tr>
		<td><img src="<%=request.getContextPath()%>/images/pxtrans.gif" width="85" height="1"></td>
		<td><img src="<%=request.getContextPath()%>/images/pxtrans.gif" width="5" height="1"></td>
		<td><img src="<%=request.getContextPath()%>/images/pxtrans.gif" width="140" height="1"></td>
		<td><img src="<%=request.getContextPath()%>/images/pxtrans.gif" width="20" height="1"></td>
		<td><img src="<%=request.getContextPath()%>/images/pxtrans.gif" width="95" height="1"></td>
		<td><img src="<%=request.getContextPath()%>/images/pxtrans.gif" width="5" height="1"></td>
		<td><img src="<%=request.getContextPath()%>/images/pxtrans.gif" width="145" height="1"></td>
		<td><img src="<%=request.getContextPath()%>/images/pxtrans.gif" width="20" height="1"></td>
		<td><img src="<%=request.getContextPath()%>/images/pxtrans.gif" width="100" height="1"></td>
		<td><img src="<%=request.getContextPath()%>/images/pxtrans.gif" width="5" height="1"></td>
		<td><img src="<%=request.getContextPath()%>/images/pxtrans.gif" width="140" height="1"></td>
	</tr>
	<tr>
		<td class="texto_grisb14" colspan="7"><bean:message key="titulo.editar.usuario"/></td>
	</tr>
	<tr>
		<td><img src="<%=request.getContextPath()%>/images/pxtrans.gif" width="1" height="10"></td>
	</tr>
	<tr>
		<td class="texto_gris"><label class="texto_rojo10">(*)&nbsp;</label><bean:message key="formulario.nombres"/></td>
		<td><img src="<%=request.getContextPath()%>/images/pxtrans.gif" width="1" height="1"></td>
		<td><input type="text" name="nombre" class="seccdINPUT140" value='<c:out value="${requestScope.usuarioTO.nombre}"/>'></td>
		<td><img src="<%=request.getContextPath()%>/images/pxtrans.gif" width="1" height="1"></td>
		<td class="texto_gris"><label class="texto_rojo10">(*)&nbsp;</label><bean:message key="formulario.ape.paterno"/></td>
		<td><img src="<%=request.getContextPath()%>/images/pxtrans.gif" width="1" height="1"></td>
		<td><input type="text" name="apePaterno" class="seccdINPUT140" value='<c:out value="${requestScope.usuarioTO.apePaterno}"/>'></td>
		<td><img src="<%=request.getContextPath()%>/images/pxtrans.gif" width="1" height="1"></td>
		<td class="texto_gris"><label class="texto_rojo10">(*)&nbsp;</label><bean:message key="formulario.ape.materno"/></td>
		<td><img src="<%=request.getContextPath()%>/images/pxtrans.gif" width="1" height="1"></td>
		<td><input type="text" name="apeMaterno" class="seccdINPUT140" value='<c:out value="${requestScope.usuarioTO.apeMaterno}"/>'></td>
		<td><img src="<%=request.getContextPath()%>/images/pxtrans.gif" width="1" height="1"></td>
    </tr>
	<tr>
		<td><img src="<%=request.getContextPath()%>/images/pxtrans.gif" width="1" height="3"></td>
	</tr>
	<tr>
		<td class="texto_gris"><label class="texto_rojo10">(*)&nbsp;</label><bean:message key="formulario.username"/></td>
		<td><img src="<%=request.getContextPath()%>/images/pxtrans.gif" width="1" height="1"></td>
		<td><input type="text" name="username" class="seccdINPUT140" value='<c:out value="${requestScope.usuarioTO.username}"/>'></td>
		<td><img src="<%=request.getContextPath()%>/images/pxtrans.gif" width="1" height="1"></td>
		<td class="texto_gris"><label class="texto_rojo10">(*)&nbsp;</label><bean:message key="formulario.perfil"/></td>
		<td><img src="<%=request.getContextPath()%>/images/pxtrans.gif" width="1" height="1"></td>
		<td>
		<select name="perfil" class="seccdSELECT140">
		<c:forEach items="${requestScope.LISTA_PERFILES}" var="perfiles" varStatus="status">
			<option value='<c:out value="${perfiles.codigo}"/>'<c:if test="${perfiles.codigo==cod_perfil}">selected</c:if>>
				<c:out value="${perfiles.nombre}"/>
			</option>
		</c:forEach>
		</select>
		</td>
		<td><img src="<%=request.getContextPath()%>/images/pxtrans.gif" width="1" height="1"></td>
		<td class="texto_gris"><label class="texto_rojo10">(*)&nbsp;</label><bean:message key="formulario.estado"/></td>
		<td><img src="<%=request.getContextPath()%>/images/pxtrans.gif" width="1" height="1"></td>
		<td>
		<select name="estado" class="seccdSELECT140">
			<c:forEach items="${requestScope.LISTA_ESTADOS}" var="estados" varStatus="status">
				<option value='<c:out value="${estados.codigo}"/>'<c:if test="${estados.codigo==cod_estado}">selected</c:if>>
				<c:out value="${estados.nombre}"/>
				</option>
			</c:forEach>
		</select>
		</td>
    </tr>
	<tr>
		<td><img src="<%=request.getContextPath()%>/images/pxtrans.gif" width="1" height="10"></td>
	</tr>
    <tr>
		<td colspan="11" class="texto_rojo" height="20"><html:errors/></td>
	</tr>
	<tr>
		<td><img src="<%=request.getContextPath()%>/images/pxtrans.gif" width="1" height="20"></td>
	</tr>
	<tr>
		<td><img src="<%=request.getContextPath()%>/images/pxtrans.gif" width="1" height="3"></td>
	</tr>
	<tr>
		<td colspan="11" align="right" >
		<a href="javascript:actualizar()" class="boton_naranja" style="height:18">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<bean:message key="boton.grabar"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</a>
		<a href="javascript:cancelar()" class="boton_naranja" style="height:18">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<bean:message key="boton.volver"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</a></td>
	</tr>		
	</table>
	</td>
</tr>
</table>
<input type="hidden" name="method">
<input type="hidden" name="codigo" value='<c:out value="${requestScope.usuarioTO.codigo}"/>'/>
</form>
</html>
